<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<f:view xmlns="http://www.w3.org/1999/xhtml"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui"
	xmlns:util="http://java.sun.com/jsf/composite/util">
	<!-- Dialogo Filtrar Atores -->
	<p:dialog appendToBody="true" closable="true" header="#{i18n.Ator_DialogoFiltrar_Header}"
		modal="false" minimizable="true" widgetVar="dialogoFiltrarAtor" width="540" resizable="false">
		<h:form id="formFiltrarAtor">
			<div class="dialogo_container_18">
				<util:dialogoLabel value="#{i18n.Ator_Nome}" />
				<div class="dialogo_grid_18">
					<p:inputText value="#{atorBean.varBuscaAtor}" styleClass="dialogo_width_18" />
				</div>
				<util:hr />
				<div class="dialogo_grid_18">
					<p:commandButton onclick="dialogoFiltrarAtor.hide()" type="button" 
						value="#{i18n.btn_Cancelar}" style="float:right"/>
					<p:commandButton action="#{atorBean.filtrar}" update="@form, :formPrincipal" 
						value="#{i18n.btn_Filtrar}" style="float:right"/>
					<p:commandButton action="#{atorBean.filtrarTodos}" update="@form, :formPrincipal" 
						value="#{i18n.btn_Todos}" style="float:right"/>
				</div>
			</div>	
		</h:form>
	</p:dialog>
	
	<!-- Dialogo Novo Ator -->
	<p:dialog appendToBody="true" closable="true" header="#{i18n.Ator_DialogoFiltrar_Header}"
		modal="false" minimizable="true" widgetVar="dialogoNovoAtor" width="540" resizable="false">
		<h:form id="formNovoAtor">
			<div class="dialogo_container_18">
				<div class="dialogo_grid_18">
					<p:messages id="messageNovoAtor" />
				</div>
				<util:dialogoLabel value="#{i18n.Ator_Nome}" />
				<div class="dialogo_grid_18">
					<p:inputText value="#{atorBean.atorInstance.nome}" styleClass="dialogo_width_18" 
						required="true" requiredMessage="#{i18n.Ator_Required_Nome}" maxlength="128"/>
				</div>
				<util:hr />
				<div class="dialogo_grid_18">
					<p:commandButton onclick="dialogoNovoAtor.hide()" type="button" 
						value="#{i18n.btn_Desistir}" style="float:right"/>
					<p:commandButton action="#{atorBean.salvar}" update="@form, :formPrincipal" 
						value="#{i18n.btn_Salvar}" style="float:right"/>
				</div>
			</div>	
		</h:form>
	</p:dialog>
	
	<!-- Dialogo Editar Ator -->
	<p:dialog appendToBody="true" closable="true" header="#{i18n.Ator_DialogoFiltrar_Header}"
		modal="false" minimizable="true" widgetVar="dialogoEditarAtor" width="540" resizable="false">
		<h:form id="formEditarAtor">
			<div class="dialogo_container_18">
				<div class="dialogo_grid_18">
					<p:messages id="messageNovoAtor" />
				</div>
				<util:dialogoLabel value="#{i18n.Ator_Nome}" />
				<div class="dialogo_grid_18">
					<p:inputText value="#{atorBean.atorInstance.nome}" styleClass="dialogo_width_18" 
						required="true" requiredMessage="#{i18n.Ator_Required_Nome}" maxlength="128"/>
				</div>
				<util:hr />
				<div class="dialogo_grid_18">
					<p:commandButton onclick="dialogoEditarAtor.hide()" type="button" 
						value="#{i18n.btn_Desistir}" style="float:right"/>
					<p:commandButton action="#{atorBean.salvar}" update="@form, :formPrincipal" 
						value="#{i18n.btn_Salvar}" style="float:right"/>
				</div>
			</div>	
		</h:form>
	</p:dialog>
	
	<util:dialogoExcluir ide="Excluir" update=":formPrincipal" action="#{atorBean.goDelete}" msg="#{atorBean.msgExclusao}" />
	
	<util:dialogoSelecione />
</f:view>
